function [RM_Mean_Dist, Shuffle_RM_Mean_Dist] = RM_Mean_Dist_One_Animal_One_Dose(Data_Summary, drug, animalID)

for n=1:size(Data_Summary,2)
    if contains(Data_Summary(n).drug, drug) && contains(Data_Summary(n).animalName, animalID)
        RM_Dist(n,:)=Data_Summary(n).RateMapCorr_Proportion;
    end
end
for n=1:size(RM_Dist,1)
    if max(RM_Dist(n,:))==0
        RM_Dist(n,:)=nan;
    end
end
for n = 1:size(RM_Dist,2)
    RM_Mean_Dist(1,n) = mean(RM_Dist(:,n), 'omitnan');
end


for n=1:size(Data_Summary,2)
    if contains(Data_Summary(n).drug, drug) && contains(Data_Summary(n).animalName, animalID)
        Shuffle_RM_Dist(n,:)=Data_Summary(n).Shuffled_RateMapCorr_Proportion;
    end
end
for n=1:size(Shuffle_RM_Dist,1)
    if max(Shuffle_RM_Dist(n,:))==0
       Shuffle_RM_Dist(n,:)=nan;
    end
end
for n = 1:size(RM_Dist,2)
    Shuffle_RM_Mean_Dist(1,n) = mean(Shuffle_RM_Dist(:,n), 'omitnan');
end

end